/**
 * 
 */
package ar.unq.edu.svnpermission.persist;

import java.util.Map;

import org.uqbar.commons.home.db4o.DB4OHomeImpl;
import org.uqbar.commons.model.Home;
import ar.edu.unq.svnpermission.domain.Folder;
import ar.edu.unq.svnpermission.domain.Group;
import ar.edu.unq.svnpermission.domain.Permission;
import ar.edu.unq.svnpermission.domain.User;
import ar.unq.edu.svnpermission.homes.FolderHome;
import ar.unq.edu.svnpermission.homes.GroupHome;
import ar.unq.edu.svnpermission.homes.PermissionHome;
import ar.unq.edu.svnpermission.homes.UserHome;

/**
 * Representa un factory para persistir sobre BD Db4o
 * @author nicolas
 */
public class Db4oHomeFactory implements HomeFactory{
	public void addHomes(Map<Class<?>, Home<?>> homes) {
		homes.put(Folder.class, new FolderHome(Folder.class));
		homes.put(User.class, new UserHome(User.class));
		homes.put(Group.class, new GroupHome(Group.class));
		homes.put(Permission.class,new PermissionHome(Permission.class));
	}
}
